package Day03;

import java.util.Scanner;

public class IfElseDemo {
    public static void main(String[] args) {
        //满500打8折
        //不满500打9折
        Scanner scanner=new Scanner(System.in);
        System.out.println("请输入消费金额");
        double price= scanner.nextDouble();
        if (price>=500){
            System.out.println(price*0.8);

        }else {
            System.out.println(price*0.9);
        }
    }
}
